package com.hilin.hilinim.netty.ws.etcd;

import mousio.etcd4j.EtcdClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class HilinEtcdMqClient {

    @Autowired
    private EtcdClient client;

    public void send(String msg) {
        try {
            client.put(HilinEtcdMqConfig.EK_MSG_LISTENER, msg).send();
        } catch (Exception e) {
            e.printStackTrace();
        }
    }

}
